package cn.kent.service;

import cn.kent.entity.User;
import cn.kent.mapper.UserMapper;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class UserService extends ServiceImpl<UserMapper, User> {

    public void updateUsernameById(String id, String name) {
        this.baseMapper.updateUsernameById(id, name);
    }

    public int updatePassword(User user) {
        return this.baseMapper.updatePassword(user);
    }

    public List<User> selectPageList(Page<User> page) {
        return this.baseMapper.selectPageList(page);
    }
}
